<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <!-- 准备好一个容器 -->
    <div id="test"></div>
    <!-- 引入react库(基于react16.4) -->
    <script src="../js/react.development.js"></script>
    <script src="../js/react-dom.development.js"></script>


    <script type="text/javascript"> /* 此处一定要写babel, 因为是jsx内容 */
        // 1. 创建虚拟dom
        // 2. 渲染虚拟dom到页面
        const VDOM = React.createElement('h1',{id: 'title'}, 'hello, React');
        ReactDOM.render(VDOM, document.getElementById('test'));
    </script>
</body>
</html>